<html>
<head><meta charset="utf-8"><title>unit tests for codegen · t-compiler/help · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/index.html">t-compiler/help</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/unit.20tests.20for.20codegen.html">unit tests for codegen</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="204564405"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/unit%20tests%20for%20codegen/near/204564405" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jason Hu <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/unit.20tests.20for.20codegen.html#204564405">(Jul 21 2020 at 15:42)</a>:</h4>
<p>I am wondering how the unit tests infrastructure works in rustc? I see the <code>tests/</code> folder but it seems only contain integration tests. I am wondering whether unit tests exit, especially for codegen? if not, how do you test codegen?</p>



<a name="204565029"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/unit%20tests%20for%20codegen/near/204565029" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jonas Schievink  [he/him] <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/unit.20tests.20for.20codegen.html#204565029">(Jul 21 2020 at 15:47)</a>:</h4>
<p>There are a few unit tests in the various compiler crates, but mostly just for data structures and generic algorithms. There are none for codegen I believe.</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>